package com.example.gokchinesefoodmappcdev.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.example.gokchinesefoodmappcdev.entity.GoodsInfo;
import com.example.gokchinesefoodmappcdev.entity.GoodsSku;
import com.example.gokchinesefoodmappcdev.entity.dto.GoodsDTO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.bind.annotation.RequestParam;
@Mapper
public interface GoodsSkuDao extends BaseMapper<GoodsSku> {



    int insertSkuInfo(@Param("goodId") Integer goodId,@Param("attrSymbolPath") String attrSymbolPath,@Param("price") Double price,@Param("sales") Integer sales,@Param("stock") Integer stock,@Param("weight") String weight);

    String selectPicPathByGoodId(Integer goodId);

    int updateSkuPicByGoodIdAndPicPath(@Param("goodId")Integer goodId,@Param("picPath") String picPath);

    int updateSkuInfo(@RequestParam("id") Integer id,@RequestParam("price") Double price,@RequestParam("stock") Integer stock,@RequestParam("weight") String weight);
}
